package lab04.test01;

public class HelloWorldThread extends Thread {
    public void run(){
        //不停的向控制台输入Hello World！

        while (true){
            try {
                Thread.sleep(1000);//单位是毫秒
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
            System.out.println("Hello World!");
        }
    }
}
